import service from "../utils/request";

//一个接口封装成一个函数
export function banner_list( payload = {} ){
    return service({
        url:'/banner/list',
        method:'get',
        params: payload
    })
}

export function index_catelist( payload = {} ){
    return service({
        url:'/index/catelist',
        method:'get',
        params: payload
    })
}
export function pro_seckilllist( payload = {} ){
    return service({
        url:'/pro/seckilllist',
        method:'get',
        params: payload
    })
}
export function pro_recommendlist( payload = {} ){
    return service({
        url:'/pro/recommendlist',
        method:'get',
        params: payload
    })
}
export function user_login( payload = {} ){
    return service({
        url:'/user/login',
        method:'post',
        data: payload
    })
}

//  请求地址以 http 开头, 则不再走代理( 代理不再生效 )
//  请求地址以 /api 开头, 一定会走代理( 代理生效 )

// export function user_login( payload = {} ){
//     return service({
//         url:'http://180.76.99.14/api/user/login',
//         method:'post',
//         data: payload
//     })
// }

